When a processor of a data processing device works, a memory database is usually created in a memory, so as to accelerate data search and to avoid that data is traversed and searched from a hard disk by accessing the hard disk over a disk input/output (I/O) port. An index table in the memory database stores an index record, and data in the hard disk may be indexed according to the index record. In this way, during data search using a keyword, an index record of a corresponding record in the index table in the memory is first searched for according to a value of the keyword. If a pointer in the index record directly points to data mapped to the value of the keyword, data is read according to the found index record. If the pointer in the index record does not directly point to the data mapped to the value of the keyword, a search range of the data may be narrowed according to the index record, and the index record of the data is further searched for with reference to a mapping table in the hard disk. An index record in the mapping table in the hard disk includes a pointer pointing to the data, and the data mapped to the value of the keyword is read according to the pointer. After the index record corresponding to the keyword is found, it is determined, by searching, whether data corresponding to the index record is stored in the memory. If the memory stores the data, the processor directly reads the data from the memory. If the memory does not store the data, the processor reads the data from the hard disk according to the index record.
A data amount in a big data application scenario is relatively large. However, storage space for storing an index record in the memory is limited, the storage space is generally far less than a storage capacity of a hard disk, and not all index records in the hard disk can be loaded to the memory to improve searching performance. Therefore, a proper policy needs to be used to determine an index record to be loaded to the memory to improve retrieval efficiency, thereby further improving system performance.